package spm.entities;

import java.util.Date;
import java.util.HashSet;
import java.util.Set;

/**
 * This is a persistent class used by Hibernate. The class represents a project.
 * 
 * @author Evgeny Ryzhkov
 * 
 * $Id: Project.java 11 2006-12-04 15:04:58Z evgeny.ryzhkov $
 */
public class Project {

	/**
	 * The unique ID of the project
	 */
	private Long id;

	/**
	 * The project short name.
	 */
	private String projectName;

	/**
	 * The project description.
	 */
	private String projectDescription;

	/**
	 * The project start date.
	 */
	private Date startDate;

	/**
	 * The esimated end date of the project.
	 */
	private Date estimatedFinishDate;

	/**
	 * The actual end date of the project.
	 */
	private Date actualFinishDate;

	/**
	 * The date the project was created.
	 */
	private Date createDate;

	/**
	 * The project status.
	 */
	private ProjectStatus projectStatus;

	/**
	 * The project tasks.
	 */
	private Set tasks = new HashSet();

	/**
	 * The creator of the project.
	 */
	private User creator;

	/**
	 * All roles defined for the project
	 */
	private Set projectRoles = new HashSet();

	/**
	 * All members assigned to the project
	 */
	private Set projectMembers = new HashSet();

	/**
	 * Constructor without parameters. It is required by Hibernate.
	 */
	public Project() {
	}

	/**
	 * @return Returns the actualFinishDate.
	 */
	public Date getActualFinishDate() {
		return actualFinishDate;
	}

	/**
	 * @param actualFinishDate
	 *            The actualFinishDate to set.
	 */
	public void setActualFinishDate(Date actualFinishDate) {
		this.actualFinishDate = actualFinishDate;
	}

	/**
	 * @return Returns the createDate.
	 */
	public Date getCreateDate() {
		return createDate;
	}

	/**
	 * @param createDate
	 *            The createDate to set.
	 */
	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

	/**
	 * @return Returns the estimatedFinishDate.
	 */
	public Date getEstimatedFinishDate() {
		return estimatedFinishDate;
	}

	/**
	 * @param estimatedFinishDate
	 *            The estimatedFinishDate to set.
	 */
	public void setEstimatedFinishDate(Date estimatedFinishDate) {
		this.estimatedFinishDate = estimatedFinishDate;
	}

	/**
	 * @return Returns the id.
	 */
	public Long getId() {
		return id;
	}

	/**
	 * @param id
	 *            The id to set.
	 */
	public void setId(Long id) {
		this.id = id;
	}

	/**
	 * @return Returns the projectDescription.
	 */
	public String getProjectDescription() {
		return projectDescription;
	}

	/**
	 * @param projectDescription
	 *            The projectDescription to set.
	 */
	public void setProjectDescription(String projectDescription) {
		this.projectDescription = projectDescription;
	}

	/**
	 * @return Returns the projectName.
	 */
	public String getProjectName() {
		return projectName;
	}

	/**
	 * @param projectName
	 *            The projectName to set.
	 */
	public void setProjectName(String projectName) {
		this.projectName = projectName;
	}

	/**
	 * @return Returns the startDate.
	 */
	public Date getStartDate() {
		return startDate;
	}

	/**
	 * @param startDate
	 *            The startDate to set.
	 */
	public void setStartDate(Date startDate) {
		this.startDate = startDate;
	}

	/**
	 * @return Returns the projectStatus.
	 */
	public ProjectStatus getProjectStatus() {
		return projectStatus;
	}

	/**
	 * @param projectStatus
	 *            The projectStatus to set.
	 */
	public void setProjectStatus(ProjectStatus projectStatus) {
		this.projectStatus = projectStatus;
	}

	/**
	 * @return Returns the tasks.
	 */
	public Set getTasks() {
		return tasks;
	}

	/**
	 * @param tasks
	 *            The tasks to set.
	 */
	public void setTasks(Set tasks) {
		this.tasks = tasks;
	}

	/**
	 * @return the creator
	 */
	public User getCreator() {
		return creator;
	}

	/**
	 * @param creator
	 *            the creator to set
	 */
	public void setCreator(User creator) {
		this.creator = creator;
	}

	/**
	 * @return the projectRoles
	 */
	public Set getProjectRoles() {
		return projectRoles;
	}

	/**
	 * @param projectRoles
	 *            the projectRoles to set
	 */
	public void setProjectRoles(Set projectRoles) {
		this.projectRoles = projectRoles;
	}

	/**
	 * @return Returns the projectMembers.
	 */
	public Set getProjectMembers() {
		return projectMembers;
	}

	/**
	 * @param projectMembers
	 *            The projectMembers to set.
	 */
	public void setProjectMembers(Set projectMembers) {
		this.projectMembers = projectMembers;
	}

}
